﻿@model MvcOrganizer.Models.Report

@{
    ViewBag.Title = "EditReport";
}

<h2>EditReport</h2>

@using (Html.BeginForm())
{
    @Html.AntiForgeryToken()
    @Html.ValidationSummary(true)

    @Html.HiddenFor(model => model.ID)
    
    <div class="form_settings">
        <p>
            @Html.LabelFor(model => model.ReportType)
            @Html.DropDownListFor(model => model.ReportType, new SelectList(new List<Object>{ 
                       new { value = "Bug" , text = "Bug"  },
                       new { value = "Sugestion" , text = "Sugestion" }                     
                    }, "value", "text", 0))
            @Html.ValidationMessageFor(model => model.ReportType)
        </p>
        <p>
            @Html.LabelFor(model => model.Message)
            @Html.EditorFor(model => model.Message)
            @Html.ValidationMessageFor(model => model.Message)
        </p>
        <p>
            @Html.LabelFor(model => model.State)
            @Html.DropDownListFor(model => model.State, new SelectList(new List<Object>{ 
                       new { value = "Initial" , text = "Initial"  },
                       new { value = "Active" , text = "Active"  },
                       new { value = "Resolved" , text = "Resolved" }                     
                    }, "value", "text", 0))
            @Html.ValidationMessageFor(model => model.State)
        </p>
        <p>
            @Html.LabelFor(model => model.CreatedDate)
            @Html.EditorFor(model => model.CreatedDate)
            @Html.ValidationMessageFor(model => model.CreatedDate)
        </p>
        <p style="padding-top: 15px">
            <span>&nbsp;</span>
            <input type="submit" value="Save" class="submit" />
        </p>
    </div>   
}
<div>
    @Html.ActionLink("Back to List", "Index")
</div>
